<extend name="Public/base"/>

<block name="body">
	<!-- 标题栏 -->
	<div class="main-title">
		<h2><a href="{:U('Admin/User/index')}">用户列表</a></h2>
	</div>
	<!-- 数据列表 -->
	<div class="data-table table-striped">
		<table class="">
			<thead>
			<tr>
				<th class="">UID</th>
				<th class="">昵称</th>
				<th class="">联系人</th>
				<th class="">手机号码</th>
				<th class="">邮箱</th>

				<th class="">公众号名称</th>
				<th class="">原始ID</th>
				<th class="">微信号</th>
				<th class="">公众号绑定</th>
				<th class="">应用ID</th>
				<th class="">应用密钥</th>
				<th class="">EncodingAESKey</th>
				<th class="">GammaAppId</th>
				<th class="">GammaSecret</th>
				<th class="">是否初始化</th>
				<th class="">是否审核</th>
				<th class="">审核通过</th>
			</tr>
			</thead>
			<tbody>
			<tr>
				<td>{$ucanter.uid}</td>
				<td>{$ucanter.nickname}</td>
				<td>{$ucanter.truename}</td>
				<td>{$ucanter.mobile}</td>
				<td>{$ucanter.email}</td>

				<td>{$public.public_name}</td>
				<td>{$public.public_id}</td>
				<td>{$public.wechat}</td>
				<td>
					<if condition="$ucanter.has_public eq 0">
						无公众号
						<else/>
						认证服务号
					</if>
				</td>
				<td>{$public.appid}</td>
				<td>{$public.secret}</td>
				<td>{$public.encodingaeskey}</td>
				<td>{$ucanter.GammaAppId}</td>
				<td>{$ucanter.GammaSecret}</td>
				<td>
					<eq name="ucanter.is_init" value="0">
						否
						<else/>
						是
					</eq>
				</td>
				<td>
					<eq name="ucanter.is_audit" value="0">
						否
						<else/>
						是
					</eq>
				</td>

				<td>
					<eq name="ucanter.is_audit" value="1">
						<a href="{:U('User/changeAudit?is_audit='.$ucanter[is_audit].'&uid='.$ucanter['uid'])}"
						   class="ajax-get">不通过</a>
						<else/>
						<a href="{:U('User/changeAudit?is_audit='.$ucanter[is_audit].'&uid='.$ucanter['uid'])}"
						   class="ajax-get">通过</a>
					</eq>
				</td>
			
			</tr>
			</tbody>
		</table>
	</div>
</block>

<block name="script">
	<script src="__STATIC__/thinkbox/jquery.thinkbox.js?v={:SITE_VERSION}"></script>

	<script type="text/javascript">
		//搜索功能
		$("#search").click(function () {
			var url = $(this).attr('url');
			var query = $('.search-form').find('input').serialize();
			query = query.replace(/(&|^)(\w*?\d*?\-*?_*?)*?=?((?=&)|(?=$))/g, '');
			query = query.replace(/^&/g, '');
			if (url.indexOf('?') > 0) {
				url += '&' + query;
			} else {
				url += '?' + query;
			}
			window.location.href = url;
		});
		//回车搜索
		$(".search-input").keyup(function (e) {
			if (e.keyCode === 13) {
				$("#search").click();
				return false;
			}
		});
		//导航高亮
		highlight_subnav('{:U('
		User / index
		')}'
		)
		;
	</script>
</block>
